#! /bin/bash -x

# ssh  -i id_rsa-pstam-keypair ubuntu@ec2-23-20-125-28.compute-1.amazonaws.com


# print "hello M2PGI students":
# ssh -i /home/vince/boulot/fac/2011-2012/ecom/3svn-ecom/ecom-coloc/branches/ecom/src/main/java/ecom/id_rsa-pstam-keypair ubuntu@ec2-23-20-125-28.compute-1.amazonaws.com 'source ~/.bashrc; sh hadoop-0.20.2/data/hello.sh' 

# LINES=10
# if [ $# -eq '1' ] ; then
# 	echo "un param : $1"
#     LINES=$1
# fi

# call to hours : on peut lui passer un nombre de fichiers en parametre, par défaut = 10
ssh -i /home/vince/boulot/fac/2011-2012/ecom/3svn-ecom/ecom-coloc/branches/ecom/src/main/java/ecom/id_rsa-pstam-keypair ubuntu@ec2-23-20-125-28.compute-1.amazonaws.com "source ~/.bashrc; sh hadoop-0.20.2/data/call_hours.sh" > result_hours.txt


##! /bin/bash

# #LINES=10
# #if [ $# -eq 1 ] ; then
# #       LINES=$1
# #fi

# cd hadoop-0.20.2/data

# if [ -e hours ] ; then
#         cat hours

# else 
#         rake hours && cat hours
# fi
